<template>
  <div class="bgff p20">
    <el-form :inline="true" :model="formInline" class="demo-form-inline mb20">
      <el-form-item>
        <el-input v-model="formInline.input" placeholder="请输入用户名"></el-input>
      </el-form-item>
      <el-form-item>
        <el-input v-model="formInline.input" placeholder="客户手机号码"></el-input>
      </el-form-item>
      <el-form-item>
        <el-input v-model="formInline.input" placeholder="客户地址"></el-input>
      </el-form-item>
      <el-form-item>
        <el-input v-model="formInline.input" placeholder="申请类型"></el-input>
      </el-form-item>
      <el-form-item>
        <el-button size="small" type="primary" icon="el-icon-search">搜索</el-button>
      </el-form-item>
      <!-- <el-form-item>
        <el-button size="small" type="primary" icon="el-icon-plus" @click="addWork">添加</el-button>
      </el-form-item> -->
    </el-form>
    <div>
      <el-table :data="tableData" border style="width: 100%">
        <el-table-column type="index" width="50"></el-table-column>
        <el-table-column prop="type" label="申请类型" min-width="120"></el-table-column>
        <el-table-column prop="name" label="客户名称" min-width="120"></el-table-column>
        <el-table-column prop="phone" label="客户手机号码" min-width="150"></el-table-column>
        <el-table-column prop="address" label="区域名称" min-width="120"></el-table-column>
        <el-table-column prop="og" label="组织机构名称" min-width="150"></el-table-column>
        <el-table-column prop="status" label="流程状态" min-width="120"></el-table-column>
        <el-table-column prop="jie" label="工作流节点" min-width="120"></el-table-column>
        <el-table-column prop="date" label="备用号码" min-width="150"></el-table-column>
        <el-table-column prop="address" label="客户地址" min-width="150"></el-table-column>
        <el-table-column prop="content" label="申请内容" min-width="150"></el-table-column>
        <el-table-column prop="date" label="创建时间" min-width="150"></el-table-column>
        <el-table-column prop="date" label="修改时间" min-width="150"></el-table-column>
        <el-table-column fixed="right" label="操作" width="150">
          <template slot-scope="scope">
            <dotag :datarow="scope.row"></dotag>
            <!-- <el-button @click="handleClick(scope.row)" type="text" size="small">流程详情</el-button> -->
          </template>
        </el-table-column>
      </el-table>
    </div>
    
    <addwork ref="obj"></addwork>
  </div>
</template>

<script>
import addwork from "./modul/addwork";

import dotag from "./modul/dotag";
export default {
  components: { addwork, dotag },
  name: "adduser",
  data() {
    return {
      dialogFormVisible: false,
      form: {
        name: "",
        region: "",
        date1: "",
        date2: "",
        delivery: false,
        type: [],
        resource: "",
        desc: ""
      },
      formInline: {
        input: ""
      },
      tableData: [
        {
          date: "2016-05-02",
          type: "安装申请",
          name: "王小虎",
          role: "普通用户",
          status: "处理中",
          jie: "安装审核",
          og: "尊古科技演示",
          content: "这是申请内容",
          phone: "15680529067",
          address: "上海市普陀区金沙江路",
          zip: 200333
        },
        {
          date: "2016-05-04",
          type: "故障申报",
          name: "王小虎",
          role: "普通用户",
          status: "处理中",
          jie: "安装审核",
          og: "尊古科技演示",
          content: "这是申请内容",
          phone: "15680529067",
          address: "上海市普陀区金沙江路",
          zip: 200333
        },
        {
          date: "2016-05-01",
          type: "隐患处理",
          name: "王小虎",
          role: "技术员",
          status: "处理中",
          jie: "安装审核",
          og: "尊古科技演示",
          content: "这是申请内容",
          phone: "15680529067",
          address: "上海市普陀区金沙江路",
          zip: 200333
        },
        {
          date: "2016-05-03",
          type: "安装申请",
          name: "王小虎",
          role: "代理商",
          status: "处理中",
          jie: "安装审核",
          og: "尊古科技演示",
          content: "这是申请内容",
          phone: "15680529067",
          address: "上海市普陀区金沙江路",
          zip: 200333
        }
      ]
    };
  },
  methods: {
   
    addWork() {
      const _this = this.$refs.obj;
      _this.dialog = true;
    },
    handleCommand(v,i) {
      console.log(v,i)
    }
  }
};
</script>

<style lang="scss" scoped>
</style>
